import java.util.Scanner;

public class Demo2 {


    public  static  void main(String[] args) {


        Scanner scan = new Scanner(System.in);

        while(scan.hasNext()) {
            int m = scan.nextInt();
            int n = scan.nextInt();

            System.out.println(fun(m,n));
        }
    }

    public  static  int fun(int m, int n) {
        if(n==1 && m >=1 || m == 1 && n >=1) {
            return m + n;
        }

        return fun(m -1,n) + fun(m,n-1);
    }
}
